package com.sy.easycms.dao.mysql;

import java.sql.Connection;
import java.sql.DriverManager;

import com.sy.easycms.Config;

public class SYConnection {

	public SYConnection() {
	}

	public static Connection getConnection()
	{
		try{
			Class.forName("com.mysql.jdbc.Driver");
			Connection conn = DriverManager.getConnection(Config.connstr);
			return conn;
		}catch(Exception ex)
		{
			//TODO 加入日志记录
			ex.printStackTrace();
		}
		return null;
	}
}
